package com.lzh.service.Impl;

import com.lzh.dao.AccountMapper;
import com.lzh.pojo.Account;
import com.lzh.service.AccountService;
import org.springframework.stereotype.Service;

import java.util.List;
@Service("AccountServiceImpl")
public class AccountServiceImpl implements AccountService {

    private AccountMapper accountMapper;

    public void setAccountMapper(AccountMapper accountMapper) {
        this.accountMapper = accountMapper;
    }

    @Override
    public int addAcount(Account account) {
        return accountMapper.addAcount(account);
    }

    @Override
    public int deleteById(int id) {
        return accountMapper.deleteById(id);
    }

    @Override
    public Account selectById(int id) {
        return accountMapper.selectById(id);
    }

    @Override
    public List<Account> selectAllAccount() {
        return accountMapper.selectAllAccount();
    }

    @Override
    public int updateAccount(Account account) {
        return accountMapper.updateAccount(account);
    }
}
